<?php

class ErrorController extends BaseController
{
    // 从2.1开始, errorAction支持直接通过参数获取异常
    public function errorAction($exception)
    {
        $this->log($exception->getCode() . ' ' . $exception->getMessage());
        $this->result( 'fail',null,['debug'=>$exception->getMessage()]);
    }
}
